package com.example.graduation.entity.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.sql.Timestamp;

/**
 * @author Jeffery
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value = "chat实体类对象")
@TableName("chat")
public class Chat implements Serializable {
    @ApiModelProperty(name = "chatId", value = "聊天记录ID")
    @TableId(value = "chat_id", type = IdType.ASSIGN_ID)
    private String chatId;

    @ApiModelProperty(name = "chatSendUserId", value = "发送者用户ID")
    @TableField(value = "chat_send_user_id")
    private String chatSendUserId;

    @ApiModelProperty(name = "chat_accept_user_id", value = "接收者用户ID")
    @TableField(value = "chat_accept_user_id")
    private Timestamp chatAcceptUserId;

    @ApiModelProperty(name = "chat_create_time", value = "聊天创建时间")
    @TableField(value = "chat_create_time")
    private Timestamp createTime;

    @ApiModelProperty(name = "chat_is_deleted", value = "逻辑删除 0:未删除 1:已删除")
    @TableField(value = "chat_is_deleted")
    private int isDeleted;
}
